package com.dongdongshop.api;

import com.dongdongshop.data.Result;
import com.dongdongshop.dto.AddressDTO;
import com.dongdongshop.dto.TbUserDTO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient("dongdongshop-user-service")
public interface UserServiceApi {
    @PostMapping("/user/userByName")
    Result<TbUserDTO> userByName(@RequestParam String username);

    //根据id查询地址信息
    @PostMapping("/address/selectById")
    Result<AddressDTO> selectById(@RequestParam Long id);
}
